From 3c75004474b099ff695c0d3d1835c245a550f12f Mon Sep 17 00:00:00 2001 From: Federico Mena Quintero Date: Wed, 17 Jun 2009 20:33:57 -0500 Subject: [PATCH] Don't set the sort column when there is no model We can't set the sort column when we load the GtkFileChooser's settings, as the file models may not have been created yet. Wait until the models are actually present; then we can set the sort column. Signed-off-by: Federico Mena Quintero --- gtk/gtkfilechooserdefault.c | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/gtk/gtkfilechooserdefault.c b/gtk/gtkfilechooserdefault.c index 7dc98676e4..2e5233cf8b 100644 --- a/gtk/gtkfilechooserdefault.c +++ b/gtk/gtkfilechooserdefault.c @@ -6114,7 +6114,10 @@ settings_load (GtkFileChooserDefault *impl) impl->sort_column = sort_column; impl->sort_order = sort_order; - set_sort_column (impl); + /* We don't call set_sort_column() here as the models may not have been + * created yet. The individual functions that create and set the models will + * call set_sort_column() themselves. + */ } static void -- 2.30.2